﻿using System;
using Microsoft.SPOT;

namespace Flight.Controller.Entities
{
    public abstract class EnginePosition
    {
        /// <summary>
        /// Gets or sets the center to center distance in millimeters between engine and airplane center.
        /// </summary>
        public ushort DistanceToCenter { get; set; }

        /// <summary>
        /// Gets or sets the engine alignment.
        /// </summary>
        public EnginePositionAlignment Alignment { get; set; }

        /// <summary>
        /// Gets or sets the engine direction.
        /// </summary>
        public EnginePositionDirection Direction { get; set; }

        /// <summary>
        /// Gets or sets the engine side.
        /// </summary>
        public EnginePositionSide Side { get; set; }

        /// <summary>
        /// Retrieves the engine position description.
        /// </summary>
        /// <returns></returns>
        public virtual string GetDescription()
        {
            return "Engine : " + Alignment.ToString() + ", " + Direction.ToString() + ", " + Side.ToString();
        }
    }

    public enum EnginePositionSide
    {
        LEFT = 1,
        RIGHT = 2,
        CENTER = 3
    }

    public enum EnginePositionAlignment
    {
        FRONT = 1,
        BACK = 2,
        CENTER = 3
    }

    public enum EnginePositionDirection
    {
        UNDER = 1,
        OVER = 2
    }
}
